1. Field of the Invention
The present invention is directed to data compression and, more particularly to further compression of already compressed video.
2. Description of the Related Art
Image (e.g., video) data is often compressed or processed by using wavelet analysis. Wavelets are mathematical functions that can segment a digital signal into different frequency bands. Wavelets have some advantages over Fourier transforms, but are roughly analogous. Known compression systems convert raw image data into wavelet transform data, then run-length encode or Hoffman encode the data.
Lossy compression provides high degrees of compression and results in very small compressed files, but there is a certain amount of loss when they are restored (cf. lossless compression, which does not provide as high a degree of compression, but which does not result in any loss upon restoration). Wavelet compression is a lossy compression method used for color images and video. Instead of compressing small blocks of 8×8 pixels as in JPEG and MPEG compression methods, the wavelet algorithms compress the entire image with ratios of up to 300:1 for color and 50:1 for gray scale. An example of a codec that performs wavelet compression is the ADV601 from Analog Devices, Inc. of Norwood, Mass.
Another known way to compress video is by reducing temporal redundancy using an exclusive-OR (XOR) comparison, an example of which is illustrated in FIG. 1. In FIG. 1, previous frame 101 and current frame 102 are individual, successive frames within a video stream. Each cell of the matrices that form frames 101 and 102 in FIG. 1 (e.g., cells 104 to 111) represents a wavelet coefficient. Upon performing an XOR operation on frames 101 and 102, resultant matrix 103 is produced, which contains cells (e.g., 112-115) corresponding to the cells in the same position in frames 101 and 102, the contents of which are the result of an XOR operation on the corresponding cells in frames 101 and 102. For example, an XOR operation is performed on the contents of cells 104 and 108 which have a value of ‘0’ to produce a ‘0’ result in cell 112. The same result is produced in cells 113-115 when an XOR operation is performed on cells 105 and 109, 106 and 110, and 107 and 111, respectively, because the contents of the corresponding pairs of cells in frames 101 and 102 are identical. Upon performing an XOR operation on cells of frames 101 and 102 with differing contents, such as cells 116 and 117, which contain a ‘0’ and ‘1,’ respectively, a‘1’ results in box 118 of matrix 103.
XOR comparison is useful in video streams where each video frame image is usually the same (e.g., security cameras). XOR comparison can be used to dramatically reduce the size of the compressed file because each box of each frame is usually identical to the same box in a subsequent frame, and can therefore be compressed accordingly. However, it is not possible to perform XOR comparison after known wavelet compression of a video stream, like that performed by the ADV601, without reversing the run-length and Huffman encoding to obtain access to the wavelet coefficients.